package ui.activity.login;

import android.os.Bundle;
import android.view.View;

import base.BaseBean;
import base.activity.BaseNetActivity;
import student.andlei.com.student.R;
import ui.activity.MainActivity;
import utils.SPUtils;
import utils.StringUtils;

public class LoadingActivity extends BaseNetActivity{
    @Override
    public void success(String action, BaseBean baseBean) {



    }

    @Override
    public void error(String action, Throwable e) {

    }

    @Override
    protected int getLayoutId() {
        return R.layout.activity_loading;
    }

    @Override
    protected void findViews() {

    }

    @Override
    protected void formatViews() {
        if(StringUtils.isNull(SPUtils.getInstance(this).getString("token"))){
            jumpTo(LoginActivity.class);
        }else {
            jumpTo(MainActivity.class);
        }
        finish();
    }

    @Override
    protected void formatData() {
       // post("common/qiniuUptoken", BaseBean.class, false);
    }

    @Override
    protected void getBundle(Bundle bundle) {

    }

    @Override
    public void onClick(View v) {

    }
}
